
<template>
  <div class="f f-col h100 rel">
    <van-tree-select
      height="100%"
      :items="items"
      @click-nav="clickLeft($event)"
      :main-active-index.sync="activeIndex"
    >
      <template slot="content">
        <div v-if="activeIndex === 0" style="padding-bottom:3rem;">
          <div v-for="(item,index) in goodsList" :key="index">
            <div class="p15 p-l-0 f">
              <div class="bg round o-hide" style="width:1.5rem;min-width:1.5rem;height:1.5rem">
                <!-- <img class="w100 h100 img-cover" src="../../../static/img/c1.jpg"> -->
              </div>
              <div class="w100 pl10 pr10 rel">
                <p class="f14">农家一碗香</p>
                <div class="mt15 f j-b">
                  <em class="c2 b">￥16</em>
                </div>
                <div class="abs p0 round m-l round" style="right:0;bottom:0;">
                  <van-button type="primary" size="small" round>热售</van-button>
                </div>
              </div>
            </div>
            <div class="van-hairline--bottom"></div>
          </div>
        </div>
        <div v-else class="pt20 pb20" style="padding-bottom:3rem;">
          <van-skeleton title="" :row="8"/>
        </div>
      </template>
    </van-tree-select>
  </div>
</template>

<script>
import {
  goodsAdd,
  goodUpdate,
  goodsTypesList,
  goodsTypesAdd,
  goodsTypesUpdate,
  goodsTypesDelete,
  goodsList,
  specList,
  specAdd,
  specUpdate
} from "@/http/api";
export default {
  data() {
    return {
      goodsList: [],
      active: 0,
      // 主菜单切换
      activeIndex: 0,
      items: []
    };
  },

  created() {},

  methods: {}
};
</script>
